Returns the username of the current user logged in to Windows on the computer running the script. If scripts run remotely, the logged in username on the remote test computer is returned.
Syntax
UserName()
Return value
| Value | Description |
|---|---|
| Value | Username of the current user. |
Example
currentUser = UserName()
PrintLn("Tester: " + currentUser)